<%@page import="sdfi.lee.Newpj.DAO.AchievementDAO"%>
<%@page import="sdfi.lee.Newpj.Entity.Product"%>
<%@page import="sdfi.lee.Newpj.Entity.I_Achievement"%>
<%@page import="java.util.List"%>
<%@page import="sdfi.lee.Newpj.Entity.Achievement"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
    <%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
    <%@taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta content="<a href='<c:url value='/achievement/a_list.jsp?pg=1'/>'>最新成果</a>" name="location">
<script type="text/javascript" src="<c:url value='/js/jquery-1.6.js' />"></script>
<script type="text/javascript" src="<c:url value='/js/index.js' />"></script>
<link type="stylesheet" href="<c:url value='/css/index.css' />">
<link type="stylesheet" href="<c:url value='/css/level.css' />">
<link href="../css/index.css" rel="stylesheet" type="text/css">
<link href="../css/level.css" rel="stylesheet" type="text/css">
</head>
<body>
<%
	AchievementDAO dao=new AchievementDAO();
	List<Achievement> a_yejie=dao.getAchivement_qu(1,5);
	request.setAttribute("a_yejie",a_yejie);
	List<I_Achievement> i_list=new AchievementDAO().getI_Achievement(1,5,null,null,null,null);
	request.setAttribute("i_list",i_list);
	
	List<Product> p_list=new AchievementDAO().getProduct(1,5,null,null,null,null);
	request.setAttribute("p_list",p_list);
%>
<div class="n_div_contain">
    	<div class="n_div_head"><a  href="<c:url value='/achievement/productlist.jsp?pg=1' />">区内产品</a></div>
        <div class="n_div_show">
        	<c:forEach var="product" items="${requestScope.p_list }">
                   			<div class="newsitem">
                  		<div class="newstitle">
                  			<a href="<c:url value='/achievement/productlist.jsp?pg=1&name=${product.name}' />">${product.name}</a>
                  		</div>
                  		<div class="newsdate">&nbsp;</div>
                  	</div>
        	
        	</c:forEach>
        </div>
    </div>
    <div class="n_div_contain">
    	<div class="n_div_head"><a  href="<c:url value='/achievement/i_achilist.jsp?pg=1' />">区内成果</a></div>
        <div class="n_div_show">
        	<c:forEach var="ia" items="${requestScope.i_list }">
        	<div class="newsitem">
                   			<div class="newstitle">
                   				<a href="<c:url value='/achievement/i_achilist.jsp?pg=1&name=${ia.name}' />" >${ia.name}</a>
                   			</div>
                   			<div class="newsdate">&nbsp;</div>
                   		</div>
        		
        	</c:forEach>
        </div>
    </div>
    
    

	<div class="n_div_contain">
    	<div class="n_div_head"><a  href="<c:url value='/achievement/achilist.jsp?pg=1' />">业界成果</a></div>
        <div class="n_div_show">
     
      <c:forEach var="ache" items="${requestScope.a_yejie}">
    			  <c:choose>
					<c:when test="${ache.type==0}">
						<c:url var="acheurl" value="/achievement/achidetail.jsp?id=${ache.id}&pg=1"></c:url>
					</c:when>
					<c:otherwise>
					<c:url var="acheurl" value="/achievement/rachidetail.jsp?id=${ache.id}&path=${ache.path}&pg=1"></c:url>
					</c:otherwise>
				</c:choose>
            	 <div class="newsitem">	
            			<div class="newstitle">
            			<c:if test="${fn:contains(ache.path,'acheivement')}">
            				[<font style="color:#f56">成果</font>]
            			</c:if>
            			<c:if test="${fn:contains(ache.path,'journal')}">
            				[<font style="color:#f00">期刊</font>]
            			</c:if>
            			<c:if test="${fn:contains(ache.path,'patent')}">
            				[<font style="color:#f25">专利</font>]
            			</c:if>
            			
            			<a href="${acheurl}" title="${ache.name}">${ache.name}</a>
            			</div>
            			<div class="newsdate">
            				&nbsp;${ache.dt}
            			</div>
            	</div>
            	 </c:forEach>
        </div>
    </div>
    
    	
    
    	
</body>
</html>